Some of portable electronic devices such as an IC card and the like use a redundancy check code in order to detect a communication error in data communication with an external device. Heretofore, a portable electronic device imparts a redundancy check code to the whole of data which can be transmitted by communication of one time, and repeats retransmission processing until the external device of the transmission destination can confirm the correctness of the data. However, there is a problem that the portable electronic device takes a lot of time to carry out the retransmission processing, and there is a possibility of the communication time and the whole processing time becoming too long.